{include file="header.tpl"}

	<h1>Edit Component</h1>

   {include file="admin_sidebar.tpl"}

   <div id="content">
   
      {include file="flashes.tpl"}

   	<form id="frm_component" action="" method="post">
   
   		<fieldset class="panel">
   			
   			<div>
   				<label for="project">Project:</label>
        			<input id="project" name="project" type="text" value="{$project.description}" {$spf.readonly} />
   	 		</div>
   			
   			<div>
   				<label for="description">Description:</label>
        			<input id="description" name="description" type="text" value="{$component.description}" />
        			{if $component.errors.description}<p class="error">{$component.errors.description}</p>{/if}
   	 		</div>
   			
   			<div>
   				<label>Active:</label>
        			<div class="option">
        			   <label for="active_1" class="option"><input type="radio" id="active_1" name="active" value="1" {if $component.active}{$spf.checked}{/if} /> Yes</label>
        			</div>
        			<div class="option">
        			   <label for="active_0" class="option"><input type="radio" id="active_0" name="active" value="0" {if !$component.active}{$spf.checked}{/if} /> No</label>
        			</div>
   	 		</div>
   	 		
   		</fieldset>
   		
   		<div class="button_bar">
   			<button type="submit" name="submit_frm_component" value="1">Submit</button>
   			<button type="button" onclick="spf.navigate('projects', 'edit', '{$project.id}')">Cancel</button>
   		</div>
   		
   	</form>
   	
      <div class="clear"></div>
      
   </div>
   
{include file="footer.tpl"}
